import fetch from '@/utils/fetch'

const SpecApi = {
   // 规格组参数列表
  getPageList (params) {
    return fetch({
      url: '/api/spec/param/page',
      method: 'get',
      params: params
    })
  },
  init (params) {
    return fetch({
      url: '/api/spec/param/list',
      method: 'get',
      params: params
    })
  },
  // 添加规格组参数  
  add (params) {
    return fetch({
      url: '/api/spec/param/add',
      method: 'post',
      data: params
    })
  },
  // 修改规格组参数
  update (id, params) {
    return fetch({
      url: '/api/spec/param/' + id,
      method: 'put',
      data: params
    })
  },
  // 删除规格组参数
  del (params,businessIdParams) {
    return fetch({
      url: '/api/spec/param/' + params,
      method: 'delete',
      data:businessIdParams
    })
  },
  defaultDel (params) {
    return fetch({
      url: '/api/spec/param',
      method: 'post',
      data:params
    })
  }
}
export default SpecApi
